﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Yarp.ReverseProxy.Idenmptency.Modles;

namespace Yarp.ReverseProxy.Idenmptency
{
    /// <summary>
    /// 接口：用来存储IdenmpotencyKey和RouteId的仓储
    /// </summary>
    public interface IYarpRouteIdenmpotencyRepository
    {
        /// <summary>
        /// 保存协议
        /// </summary>
        /// <param name="yarpRouteIdIdenmpotency"></param>
        public void Save(YarpRouteIdenmpotency yarpRouteIdenmpotency);

        /// <summary>
        /// 判断该路由是否幂等
        /// </summary>
        /// <returns></returns>
        public bool IsIdenmpotencyRoute(string routeId);
    }
}
